// 平台组件暴露模块
import {
  NodeTree,
  nodeItem,
  Pagination,
  Empty
} from '@/components/index';

import TooltipBox from './components/TooltipBox.vue';

// 简洁的组件暴露
export const platformComponents = { NodeTree, nodeItem, Pagination, Empty, TooltipBox };

// 挂载到全局变量
export function setupPlatformComponents() {
  if (typeof window !== 'undefined') {
    window.platformComponents = platformComponents;
  }
}

setupPlatformComponents();

declare global {
  interface Window {
    platformComponents: typeof platformComponents;
  }
}